1. Field of the Invention
The present invention relates to a frequency generator, and more particularly, to a frequency generator capable of generating a frequency with a wide frequency range by utilizing an approximating method.
2. Description of the Prior Art
With the evolution of technology, the functions of electronic products are becoming more and more versatile while the sizes of electronic products are becoming more compact and light. These developments may lead to different types of clocks being set on a narrow, small printed circuit board. In order to generate the different types of clocks, a clock generator or an oscillator is a necessary component. However, clock generators and oscillators have frequency jitter problems, which will directly affect accuracy of the generated frequency.
To improve the frequency jitter, several studies have been made: for example, use of a frequency locked-loop (FLL) circuit and a phase locked-loop (PLL) circuit. Although these circuits improve the frequency jitter, the complexity and cost also rises. In the prior art, a clock generation circuit uses a current source to charge a capacitor through a resistor for obtaining a time constant, and a frequency associated with the time constant can be determined. That is, when a smaller resistance or capacitance is used, the capacitor is charged or discharged rapidly, and a higher frequency is generated correspondingly. When a larger resistance or capacitance is used, the capacitor is charged or discharged slowly, and thus a lower frequency is generated. Therefore, when the frequency range of the desired frequency is quite wide, this means that the resistance of the external resistor has a large variation. Since there is a large variation in resistance of the external resistor, the current through the external resistor must vary dramatically. For example, if the clock generator intends to generate a frequency of 1 Hz up to 100 Hz (e.g. the variation ratio of the frequency is 100 times), the variation ratio of the current must reach 100 times as well. It is quite difficult, however, to implement such large current variation on a practical circuit. Moreover, delays in the back stage could cause a different frequency response in both high frequency and low frequency such that the clock generator cannot generate a clock having an accurate frequency and a wide frequency range.
In addition, the external resistor is inversely proportional to the generated frequency. Therefore, when the clock generator generates a high frequency clock, a small variation in the external resistor may cause a large variation in frequency. When the clock generator generates a low frequency clock, a small variation in the external resistor may cause a large variation in frequency. In other words, when the external resistor has small resistance, this means that the clock generator generates a high frequency clock (e.g. high resolution of digital codes). When the external resistor has large resistance, this means that the clock generator generates a low frequency clock (e.g. low resolution of digital codes). Regardless of whether a high frequency or low frequency is generated, the resistance is always measured in the same resolution in the prior art, causing unnecessary resource waste.
In short, when the frequency range generated by the clock generator is quite wide, an external resistor that can vary its resistance significantly must be provided in the prior art. In this situation, large fluctuations in the current through the external resistor occur. It is hard, however, to implement a current source with large variation on the practical circuit. Besides, the clock generator needs different resolution requirements for the high frequency and the low frequency. If the same resolution is used for both cases, the system efficiency may be degraded.